﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using FsCarInfo.Core.Entity.IRespositories;
using FsCarInfo.Core.Entity.IServices;
using HMIS.FrameWork.DomainBase;
using FsCarInfo.Core.Entity;

namespace FsCarInfo.Facade.Impl
{
    public class CarTransferFacadeImpl : ICarTransferFacade
    {
        private readonly ICarTransferRepository CarTransferRepository;

		public CarTransferFacadeImpl(ICarTransferRepository CarTransferRepository)
        {
			this.CarTransferRepository = CarTransferRepository;
        }

        #region ICarFacade 成员

		public CarTransfer Get(string id)
		{
			return CarTransferRepository.Get(id);
		}

		public CarTransfer Load(string id)
		{
			return CarTransferRepository.Load(id);
		}

		public void SaveOrUpdate(CarTransfer entity)
		{
			this.CarTransferRepository.SaveOrUpdate(entity);
		}

		public void Delete(string id)
		{
			CarTransferRepository.Delete(id);
		}

		public bool IsFieldExist(string fieldName, string fieldValue, string id)
		{
			return CarTransferRepository.IsFieldExist(fieldName, fieldValue, id);
		}

		public IList<CarTransfer> GetPlist(int start, int limit, string sort, string dir, List<DataFilter> filters, out long total)
        {
			return CarTransferRepository.GetPlistAll(start, limit, sort, dir, filters, out total);
        }

		public IList<CarTransfer> QueryCarList(string query, int start, int limit, string sort, string dir, List<DataFilter> filters, out long total)
		{
			return CarTransferRepository.QueryCarList(query, start, limit, sort, dir, filters, out total);
		}

		public IList<CarTransfer> QueryPlist(string query,
			int start,
			int limit,
			string sort,
			string dir,
			List<DataFilter> filters, out long total)
		{
			return CarTransferRepository.QueryPlist(query, start, limit, sort, dir, filters, out total);
		}

        #endregion
    }
}
